package com.sun.common.result;

import java.io.Serializable;

/**
 * <pre>
 * Title :  HTTP的返回响应类
 * </pre>
 *
 * @author : SunJiYong
 * @since : 2022-02-28
 **/
public class ActionResult implements Serializable {

    private static final long serialVersionUID = -8041820346732720877L;
    private int code;// 状态编码
    private String message;// 消息

    public ActionResult() {
        super();
    }

    public ActionResult(int code, String message) {
        super();
        this.code = code;
        this.message = message;
    }

    public int getCode() {
        return code;
    }

    public void setCode(int status) {
        this.code = status;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    public static ActionResult  success(){

        return new ActionResult(200,"success");
    }
}
